<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>训管案例化教学数据资源库管理系统</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: "Microsoft YaHei", sans-serif;
        }
        
        body {
            background-color: #f5f7fa;
            color: #333;
            line-height: 1.6;
        }
        
        .container {
            display: flex;
            min-height: 100vh;
        }
        
        /* 侧边栏样式 */
        .sidebar {
            width: 250px;
            background-color: #2c3e50;
            color: #ecf0f1;
            padding: 20px 0;
            box-shadow: 2px 0 5px rgba(0,0,0,0.1);
        }
        
        .logo {
            text-align: center;
            padding: 15px 0;
            border-bottom: 1px solid #34495e;
            margin-bottom: 20px;
        }
        
        .logo h2 {
            font-size: 18px;
            font-weight: bold;
        }
        
        .menu {
            list-style: none;
        }
        
        .menu-item {
            padding: 12px 20px;
            cursor: pointer;
            transition: all 0.3s;
            border-left: 4px solid transparent;
        }
        
        .menu-item:hover {
            background-color: #34495e;
        }
        
        .menu-item.active {
            background-color: #34495e;
            border-left: 4px solid #3498db;
        }
        
        .submenu {
            list-style: none;
            margin-left: 20px;
            display: none;
        }
        
        .submenu.show {
            display: block;
        }
        
        .submenu-item {
            padding: 10px 15px;
            font-size: 14px;
            cursor: pointer;
            transition: all 0.3s;
        }
        
        .submenu-item:hover {
            background-color: #2c3e50;
            color: #3498db;
        }
        
        /* 主内容区域样式 */
        .main-content {
            flex: 1;
            padding: 20px;
            overflow-y: auto;
        }
        
        .header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 20px;
            padding-bottom: 15px;
            border-bottom: 1px solid #ddd;
        }
        
        .breadcrumb {
            font-size: 14px;
            color: #7f8c8d;
        }
        
        .breadcrumb a {
            color: #3498db;
            text-decoration: none;
        }
        
        .page-title {
            font-size: 22px;
            color: #2c3e50;
            margin-bottom: 20px;
        }
        
        /* 卡片样式 */
        .card {
            background: white;
            border-radius: 5px;
            box-shadow: 0 2px 10px rgba(0,0,0,0.05);
            margin-bottom: 20px;
            overflow: hidden;
        }
        
        .card-header {
            padding: 15px 20px;
            border-bottom: 1px solid #eee;
            font-weight: bold;
            background-color: #f9f9f9;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        
        .card-body {
            padding: 20px;
        }
        
        /* 按钮样式 */
        .btn {
            padding: 8px 15px;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-size: 14px;
            transition: all 0.3s;
        }
        
        .btn-primary {
            background-color: #3498db;
            color: white;
        }
        
        .btn-primary:hover {
            background-color: #2980b9;
        }
        
        .btn-success {
            background-color: #2ecc71;
            color: white;
        }
        
        .btn-success:hover {
            background-color: #27ae60;
        }
        
        /* 表格样式 */
        .table {
            width: 100%;
            border-collapse: collapse;
        }
        
        .table th, .table td {
            padding: 12px 15px;
            text-align: left;
            border-bottom: 1px solid #eee;
        }
        
        .table th {
            background-color: #f9f9f9;
            font-weight: 600;
        }
        
        .table tr:hover {
            background-color: #f5f7fa;
        }
        
        /* 资源卡片样式 */
        .resource-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 20px;
            margin-top: 20px;
        }
        
        .resource-card {
            background: white;
            border-radius: 5px;
            box-shadow: 0 2px 5px rgba(0,0,0,0.1);
            overflow: hidden;
            transition: transform 0.3s;
        }
        
        .resource-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 5px 15px rgba(0,0,0,0.1);
        }
        
        .resource-img {
            height: 160px;
            background-color: #eee;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #7f8c8d;
            font-size: 48px;
        }
        
        .resource-info {
            padding: 15px;
        }
        
        .resource-title {
            font-weight: bold;
            margin-bottom: 8px;
            font-size: 16px;
        }
        
        .resource-desc {
            font-size: 14px;
            color: #7f8c8d;
            margin-bottom: 15px;
        }
        
        .resource-meta {
            display: flex;
            justify-content: space-between;
            font-size: 13px;
            color: #95a5a6;
        }
        
        /* 表单样式 */
        .form-group {
            margin-bottom: 15px;
        }
        
        .form-label {
            display: block;
            margin-bottom: 5px;
            font-weight: 500;
        }
        
        .form-control {
            width: 100%;
            padding: 10px;
            border: 1px solid #ddd;
            border-radius: 4px;
            font-size: 14px;
        }
        
        /* 首页定制样式 */
        .homepage-layout {
            display: grid;
            grid-template-columns: 2fr 1fr;
            gap: 20px;
        }
        
        .layout-preview {
            background-color: #f9f9f9;
            border: 2px dashed #ddd;
            border-radius: 5px;
            min-height: 400px;
            padding: 15px;
        }
        
        .component-list {
            background-color: white;
            border-radius: 5px;
            padding: 15px;
        }
        
        .component-item {
            padding: 10px;
            background-color: #f5f7fa;
            margin-bottom: 10px;
            border-radius: 4px;
            cursor: move;
        }
        
        /* 隐藏不需要显示的内容 */
        .content-section {
            display: none;
        }
        
        .content-section.active {
            display: block;
        }
    </style>
</head>
<body>
    <div class="container">
        <!-- 侧边导航 -->
        <div class="sidebar">
            <div class="logo">
                <h2>训管案例化教学数据资源库管理系统</h2>
            </div>
            <ul class="menu">
                <li class="menu-item active" data-target="resource-library">资源库管理</li>
                <ul class="submenu show">
                    <li class="submenu-item active" data-target="lib-management">资源库管理</li>
                    <li class="submenu-item" data-target="module-management">资源模块管理</li>
                    <li class="submenu-item" data-target="homepage-custom">首页定制</li>
                </ul>
                <li class="menu-item" data-target="resource-management">资源管理模块</li>
                <ul class="submenu">
                    <li class="submenu-item" data-target="access-tracking">访问跟踪</li>
                    <li class="submenu-item" data-target="resource-access">资源访问</li>
                    <li class="submenu-item" data-target="resource-search">资源检索</li>
                    <li class="submenu-item" data-target="resource-display">资源展示</li>
                    <li class="submenu-item" data-target="resource-stats">资源排行统计</li>
                    <li class="submenu-item" data-target="resource-rating">资源评分</li>
                </ul>
                <li class="menu-item" data-target="basic-data">基础数据模块</li>
                <ul class="submenu">
                    <li class="submenu-item" data-target="dictionary-management">字典管理</li>
                    <li class="submenu-item" data-target="access-control">访问权限控制</li>
                    <li class="submenu-item" data-target="resource-control">资源权限控制</li>
                </ul>
            </ul>
        </div>
        
        <!-- 主内容区域 -->
        <div class="main-content">
            <div class="header">
                <div class="breadcrumb">
                    <a href="#">首页</a> > <a href="#" class="current-nav">资源库管理</a>
                </div>
                <div class="user-info">
                    管理员，欢迎您！ <a href="#">退出</a>
                </div>
            </div>
            
            <!-- 资源库管理内容 -->
            <div class="content-section active" id="lib-management">
                <h2 class="page-title">资源库管理</h2>
                
                <div class="card">
                    <div class="card-header">
                        <span>资源库列表</span>
                        <button class="btn btn-primary" id="create-library">创建新资源库</button>
                    </div>
                    <div class="card-body">
                        <table class="table">
                            <thead>
                                <tr>
                                    <th>资源库名称</th>
                                    <th>类型</th>
                                    <th>资源数量</th>
                                    <th>最后更新</th>
                                    <th>操作</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td>指挥训练案例库</td>
                                    <td>指挥类</td>
                                    <td>128</td>
                                    <td>2023-06-15</td>
                                    <td>
                                        <button class="btn btn-primary">编辑</button>
                                        <button class="btn btn-primary">查看模块</button>
                                    </td>
                                </tr>
                                <tr>
                                    <td>后勤管理案例库</td>
                                    <td>后勤类</td>
                                    <td>76</td>
                                    <td>2023-07-02</td>
                                    <td>
                                        <button class="btn btn-primary">编辑</button>
                                        <button class="btn btn-primary">查看模块</button>
                                    </td>
                                </tr>
                                <tr>
                                    <td>应急处突案例库</td>
                                    <td>处置类</td>
                                    <td>94</td>
                                    <td>2023-06-28</td>
                                    <td>
                                        <button class="btn btn-primary">编辑</button>
                                        <button class="btn btn-primary">查看模块</button>
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                </div>
                
                <div class="card">
                    <div class="card-header">
                        <span>创建/编辑资源库</span>
                    </div>
                    <div class="card-body">
                        <form id="library-form">
                            <div class="form-group">
                                <label class="form-label">资源库名称</label>
                                <input type="text" class="form-control" placeholder="请输入资源库名称">
                            </div>
                            <div class="form-group">
                                <label class="form-label">资源库类型</label>
                                <select class="form-control">
                                    <option>指挥类</option>
                                    <option>后勤类</option>
                                    <option>处置类</option>
                                    <option>训练类</option>
                                </select>
                            </div>
                            <div class="form-group">
                                <label class="form-label">资源库描述</label>
                                <textarea class="form-control" rows="3" placeholder="请输入资源库描述"></textarea>
                            </div>
                            <div class="form-group">
                                <label class="form-label">主题图片</label>
                                <input type="file" class="form-control">
                            </div>
                            <button type="submit" class="btn btn-success">保存资源库</button>
                        </form>
                    </div>
                </div>
            </div>
            
            <!-- 资源模块管理内容 -->
            <div class="content-section" id="module-management">
                <h2 class="page-title">资源模块管理 - 指挥训练案例库</h2>
                
                <div class="card">
                    <div class="card-header">
                        <span>模块列表</span>
                        <button class="btn btn-primary">创建新模块</button>
                    </div>
                    <div class="card-body">
                        <table class="table">
                            <thead>
                                <tr>
                                    <th>模块名称</th>
                                    <th>资源数量</th>
                                    <th>共享状态</th>
                                    <th>审核状态</th>
                                    <th>操作</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td>指挥决策案例</td>
                                    <td>42</td>
                                    <td>公开</td>
                                    <td>已审核</td>
                                    <td>
                                        <button class="btn btn-primary">编辑</button>
                                        <button class="btn btn-primary">管理资源</button>
                                    </td>
                                </tr>
                                <tr>
                                    <td>协同训练案例</td>
                                    <td>36</td>
                                    <td>公开</td>
                                    <td>已审核</td>
                                    <td>
                                        <button class="btn btn-primary">编辑</button>
                                        <button class="btn btn-primary">管理资源</button>
                                    </td>
                                </tr>
                                <tr>
                                    <td>应急处置案例</td>
                                    <td>28</td>
                                    <td>私有</td>
                                    <td>待审核</td>
                                    <td>
                                        <button class="btn btn-primary">编辑</button>
                                        <button class="btn btn-primary">管理资源</button>
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
            
            <!-- 首页定制内容 -->
            <div class="content-section" id="homepage-custom">
                <h2 class="page-title">首页定制 - 指挥训练案例库</h2>
                
                <div class="card">
                    <div class="card-header">
                        <span>首页布局定制</span>
                    </div>
                    <div class="card-body">
                        <div class="homepage-layout">
                            <div class="layout-preview">
                                <h3>首页预览</h3>
                                <p>拖拽右侧组件到此区域进行布局定制</p>
                                <div style="background: #e74c3c; color: white; padding: 20px; margin: 10px 0;">资源展示模块</div>
                                <div style="background: #3498db; color: white; padding: 20px; margin: 10px 0;">热门推荐模块</div>
                                <div style="background: #2ecc71; color: white; padding: 20px; margin: 10px 0;">资源排行模块</div>
                            </div>
                            <div class="component-list">
                                <h3>可用组件</h3>
                                <div class="component-item" draggable="true">资源展示模块</div>
                                <div class="component-item" draggable="true">热门推荐模块</div>
                                <div class="component-item" draggable="true">最新资源模块</div>
                                <div class="component-item" draggable="true">资源排行模块</div>
                                <div class="component-item" draggable="true">分类导航模块</div>
                            </div>
                        </div>
                        
                        <div style="margin-top: 20px; text-align: center;">
                            <button class="btn btn-success">保存首页布局</button>
                            <button class="btn btn-primary">预览首页效果</button>
                        </div>
                    </div>
                </div>
            </div>
            
            <!-- 资源展示内容 -->
            <div class="content-section" id="resource-display">
                <h2 class="page-title">资源展示 - 指挥决策案例</h2>
                
                <div class="card">
                    <div class="card-header">
                        <span>筛选条件</span>
                    </div>
                    <div class="card-body">
                        <div style="display: flex; gap: 15px; margin-bottom: 20px;">
                            <select class="form-control" style="width: auto;">
                                <option>全部类型</option>
                                <option>文档</option>
                                <option>图片</option>
                                <option>视频</option>
                            </select>
                            <select class="form-control" style="width: auto;">
                                <option>排序方式: 上传时间</option>
                                <option>排序方式: 浏览次数</option>
                                <option>排序方式: 评分</option>
                            </select>
                            <input type="text" class="form-control" placeholder="搜索资源" style="width: 300px;">
                        </div>
                    </div>
                </div>
                
                <div class="resource-grid">
                    <div class="resource-card">
                        <div class="resource-img">
                            <i>📄</i>
                        </div>
                        <div class="resource-info">
                            <div class="resource-title">指挥决策案例分析2023</div>
                            <div class="resource-desc">本案例详细分析了2023年指挥决策过程中的关键因素和应对策略</div>
                            <div class="resource-meta">
                                <span>📊 128 浏览</span>
                                <span>⭐ 4.5</span>
                            </div>
                        </div>
                    </div>
                    
                    <div class="resource-card">
                        <div class="resource-img">
                            <i>🎬</i>
                        </div>
                        <div class="resource-info">
                            <div class="resource-title">实战指挥视频案例</div>
                            <div class="resource-desc">实战环境下的指挥决策过程实录，包含专家点评和分析</div>
                            <div class="resource-meta">
                                <span>📊 256 浏览</span>
                                <span>⭐ 4.8</span>
                            </div>
                        </div>
                    </div>
                    
                    <div class="resource-card">
                        <div class="resource-img">
                            <i>📄</i>
                        </div>
                        <div class="resource-info">
                            <div class="resource-title">指挥系统操作手册</div>
                            <div class="resource-desc">最新指挥系统的详细操作指南和注意事项</div>
                            <div class="resource-meta">
                                <span>📊 87 浏览</span>
                                <span>⭐ 4.2</span>
                            </div>
                        </div>
                    </div>
                    
                    <div class="resource-card">
                        <div class="resource-img">
                            <i>📊</i>
                        </div>
                        <div class="resource-info">
                            <div class="resource-title">指挥效能评估报告</div>
                            <div class="resource-desc">基于多案例的指挥效能评估和分析报告</div>
                            <div class="resource-meta">
                                <span>📊 104 浏览</span>
                                <span>⭐ 4.6</span>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            
            <!-- 其他内容区域预留 -->
            <div class="content-section" id="access-tracking">
                <h2 class="page-title">访问跟踪</h2>
                <!-- 内容省略 -->
            </div>
            
            <div class="content-section" id="resource-access">
                <h2 class="page-title">资源访问</h2>
                <!-- 内容省略 -->
            </div>
            
            <!-- 更多内容区域... -->
            
        </div>
    </div>

    <script>
        document.addEventListener('DOMContentLoaded', function() {
            // 菜单切换功能
            const menuItems = document.querySelectorAll('.menu-item');
            const submenuItems = document.querySelectorAll('.submenu-item');
            const contentSections = document.querySelectorAll('.content-section');
            const breadcrumb = document.querySelector('.breadcrumb .current-nav');
            
            // 主菜单点击事件
            menuItems.forEach(item => {
                item.addEventListener('click', function() {
                    const target = this.getAttribute('data-target');
                    
                    // 切换主菜单激活状态
                    menuItems.forEach(mi => mi.classList.remove('active'));
                    this.classList.add('active');
                    
                    // 显示对应的子菜单
                    document.querySelectorAll('.submenu').forEach(sub => {
                        sub.style.display = 'none';
                    });
                    
                    if (this.nextElementSibling && this.nextElementSibling.classList.contains('submenu')) {
                        this.nextElementSibling.style.display = 'block';
                    }
                    
                    // 显示第一个子菜单内容
                    const firstSubItem = this.nextElementSibling.querySelector('.submenu-item');
                    if (firstSubItem) {
                        submenuItems.forEach(si => si.classList.remove('active'));
                        firstSubItem.classList.add('active');
                        
                        contentSections.forEach(section => section.classList.remove('active'));
                        document.getElementById(firstSubItem.getAttribute('data-target')).classList.add('active');
                        
                        // 更新面包屑导航
                        updateBreadcrumb(this.textContent, firstSubItem.textContent);
                    }
                });
            });
            
            // 子菜单点击事件
            submenuItems.forEach(item => {
                item.addEventListener('click', function() {
                    const target = this.getAttribute('data-target');
                    
                    // 切换子菜单激活状态
                    submenuItems.forEach(si => si.classList.remove('active'));
                    this.classList.add('active');
                    
                    // 显示对应内容
                    contentSections.forEach(section => section.classList.remove('active'));
                    document.getElementById(target).classList.add('active');
                    
                    // 更新面包屑导航
                    const parentMenu = this.closest('.submenu').previousElementSibling;
                    updateBreadcrumb(parentMenu.textContent, this.textContent);
                });
            });
            
            // 更新面包屑导航
            function updateBreadcrumb(menuText, submenuText) {
                breadcrumb.textContent = menuText + ' > ' + submenuText;
            }
            
            // 初始化页面
            updateBreadcrumb('资源库管理', '资源库管理');
        });
    </script>
</body>
</html>